<%--
  Created by IntelliJ IDEA.
  User: lt
  Date: 2017/5/3
  Time: 16:55
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE HTML>
<html>
<head>
    <%@ include file="/common/include-core.jsp" %>
    <title>卡券批次</title>
</head>
<body>
<article class="page-container">
    <form action="" class="form form-horizontal" id="form-member-add">
        <input id="tid" name="tid" value="${certificateBatch.tid}" type="hidden">
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red"></span>批次编号：</label>
            <div class="formControls col-xs-8 col-sm-9">
              <span>${certificateBatch.batchId}</span>
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>批次名称：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" placeholder="批次名称" value="${certificateBatch.batchName}"
                       id="batchName" name="batchName">
            </div>
        </div>



        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>卡券类型：</label>
            <div class="formControls col-xs-8 col-sm-9">

                <span class="select-box">
                     <select class="region select radius input-text" id="certificateClassifyId" name="certificateClassifyId">
                         <c:forEach items="${certificateClassifyList}" var="item">
                             <option value="${item.tid}" ${certificateBatch.certificateClassifyId==item.tid?"selected":"" }>${item.name}</option>
                         </c:forEach>
                </select>
				</span>
            </div>
        </div>



        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>发行数量：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" placeholder="发行数量(-1表示不限制数量)" value="${certificateBatch.amount}"
                       id="amount" name="amount" ${certificateBatch.batchId==null?"":"readonly"}>
            </div>
        </div>


        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3">开始时间：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" onfocus="WdatePicker({skin:'whyGreen',dateFmt:'yyyy-MM-dd'})"
                       value="<fmt:formatDate value="${certificateBatch.startDate}" pattern="yyyy-MM-dd"/>"
                       placeholder="开始时间" id="startDate" name="startDate">
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3">结束时间：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" onfocus="WdatePicker({skin:'whyGreen',dateFmt:'yyyy-MM-dd'})"
                       value="<fmt:formatDate value="${certificateBatch.endDate}"  pattern="yyyy-MM-dd"/>"
                       placeholder="结束时间" id="endDate" name="endDate">
            </div>
        </div>

        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>备注：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <input type="text" class="input-text" placeholder="备注" value="${certificateBatch.remark}" id="remark"
                       name="remark">
            </div>
        </div>


        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>状态：</label>
            <div class="formControls col-xs-8 col-sm-9">
                <span class="select-box">
                    <select class="region select radius input-text" name="batchStatus">
                        <option value="1" ${certificateBatch.batchStatus==1?"selected":"" }>有效</option>
                        <option value="0" ${certificateBatch.batchStatus==0?"selected":"" }>无效</option>
                    </select>
				</span>
            </div>
        </div>
        <div class="row cl">
            <div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
                <input class="btn btn-primary radius" type="submit" id="certificateBatchSubmit"
                       value="&nbsp;&nbsp;提交&nbsp;&nbsp;">
            </div>
        </div>
    </form>
</article>


<script type="text/javascript" src="/static/js/certificate/certificateBatch.js"></script>

</body>
</html>
